import Vue from "vue"
import Router from "vue-router"
import Index from "./views/index.vue"
import List from "./views/list.vue"
import Detail from "./views/detail.vue"
import login from "@/components/login";
import register from "@/components/register";
import personHome from "@/views/personHome";
import personInfo from "@/views/personInfo";

Vue.use(Router);

export default new Router({
    mode: "history",
    base: process.env.BASE_URL,
    routes: [
        {
            path: "*",
            redirect: "/index",
        }, {
            path: "/index",
            component: Index
        },{
            path: "/login",
            component: login
        },{
            path: "/register",
            component: register
        }, {
            path: "/list",
            component: List
        }, {
            path: "/detail/:id",
            component: Detail
        }, {
            path: "/person",
            component: personHome
        }, {
            path: "/person-info-setting",
            component: personInfo
        }]
})
